<%@ page contentType="text/html; charset=utf-8"%>
<table class="table" border="0" cellspacing="1" align="center">
<caption class="caption">角色详细信息</caption>
<tr>
<td width="63">
名称
</td>
<td width="257">
<input name="name" type="text" id="name" value="${bean.name}" />
</td>
</tr>
</table>
<script language="javascript">
       $(function(){
      tbar.removeAll(true);
      tbar.addButton([
    	   {
    	       text:'保存',
    	       handler:function(btn,eo){
    	          var act = "${param.action}";
    	          var postdata='bean.name='+$("#name").val()+"&bean.id=${bean.id}";    	          
    	          myMask.show();
    	          $.ajax({
                  type: "POST",
                  url: act+"role.action",
                  data: postdata,
                  success: function(msg){
                   // $("#debug").text(msg);                       
                  myMask.hide();            
          		  },
         		  error:function(msg){
            			alert(msg);
          		  }	
          
       			  });    
    	       }
    	    },
    	    {
    	       text:'返回职务列表',
    	       handler:function(btn,eo){
    	          doAjaxLink('${base}jsp/admin/role-list.jsp');
    	       }
    	    }    	    
       ]);    	    
      tbar.render();  
   });     
</script>